package org.dtrd.modules.record.entity.bean;

import io.swagger.annotations.ApiModelProperty;
import lombok.*;
import org.dtrd.config.system.Constant;
import org.dtrd.config.system.Constant.SigninItemPlanStatus;

import java.util.Date;

/**
 * @author 萧
 * @date:2021-12-03 3:54 下午
 **/
@Data
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode
public class DailyGroupCheckinRecord {

    @ApiModelProperty(value = "记录日期、周月标记", example = "21年10月01日或者第五周平均值")
    private String recordDate;

    @ApiModelProperty(value = "用户id")
    private Integer patientId;

    // 辅助计算字段，与接口数据无关
    private String weekStart;
    private String monthStart;
    private Date sourceDate;

    @ApiModelProperty(value = "日期特殊标记", example = "(逆转前)")
    private String dateTag;

    /**
     * {@link Constant.SigninRecordStat}
     */
    @ApiModelProperty(value = "统计标记", notes = "区分天周月，1-天，2-周，3-月，默认1")
    private Integer recordStat = 1;

    /**
     * 血糖 空腹、早餐后、午餐/晚餐前后、睡前、凌晨
     */
    @ApiModelProperty(value = "血糖标记", example = "按照设计图顺序呈现")
    private String k1=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k1State=Constant.RecordStatus.NORMAL.getType();
    /**
     * 默认未配置
     * {@link Constant.SigninItemPlanStatus}
     */
    @ApiModelProperty(value = "打卡项计划状态", notes = "1  正常  ，2 漏打 ， 3  没到时间  4  没配置计划")
    private Integer k1PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k2=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k2State=Constant.RecordStatus.NORMAL.getType();
    private Integer k2PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k3=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k3State=Constant.RecordStatus.NORMAL.getType();
    private Integer k3PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k4=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k4State=Constant.RecordStatus.NORMAL.getType();
    private Integer k4PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k5=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k5State=Constant.RecordStatus.NORMAL.getType();
    private Integer k5PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k6=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k6State=Constant.RecordStatus.NORMAL.getType();
    private Integer k6PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k7=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k7State=Constant.RecordStatus.NORMAL.getType();
    private Integer k7PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k8=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k8State=Constant.RecordStatus.NORMAL.getType();
    private Integer k8PlanState = SigninItemPlanStatus.NOPLAN.getType();

    /**
     * 饮食  早午晚
     */
    private String k9=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k9Describe;
    private Integer k9PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k10=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k10Describe;
    private Integer k10PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k11=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k11Describe;
    private Integer k11PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 运动
     */
    private String k12=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k12Describe;
    private Integer k12PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 用药 早午晚睡前
     */
    private String k13=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k13Describe;
    private Integer k13PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k14=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k14Describe;
    private Integer k14PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k15=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k15Describe;
    private Integer k15PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k16=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k16Describe;
    private Integer k16PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 胰岛素 早午晚睡
     */
    private String k17=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k17Describe;
    private Integer k17PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k18=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k18Describe;
    private Integer k18PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k19=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k19Describe;
    private Integer k19PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k20=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k20Describe;
    private Integer k20PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 作息
     */
    private String k21=SigninItemPlanStatus.NOPLAN.getStatus();
    private Integer k21PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 体重-BMI
     */
    private String k22;
    private Integer k22State;
    private Integer k22PlanState = SigninItemPlanStatus.NOPLAN.getType();

    /**
     * 尿酮
     */
    private String k23;
    private String k23Describe;
    private Integer k23PlanState = SigninItemPlanStatus.NOPLAN.getType();

    /**
     * 腰围
     */
    private String k24;
    private Integer k24State;
    private Integer k24PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 早血压  高压、低压、心率
     */
    private String k25;
    private Integer k25State;
    private Integer k25PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k26;
    private Integer k26State;
    private Integer k26PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k27;
    private Integer k27State;
    private Integer k27PlanState = SigninItemPlanStatus.NOPLAN.getType();
    /**
     * 晚血压  高压、低压、心率
     */
    private String k28;
    private Integer k28State;
    private Integer k28PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k29;
    private Integer k29State;
    private Integer k29PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k30;
    private Integer k30State;
    private Integer k30PlanState = SigninItemPlanStatus.NOPLAN.getType();

    /**
     * 营养素 早午晚睡前
     */
    private String k31=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k31Describe;
    private Integer k31PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k32=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k32Describe;
    private Integer k32PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k33=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k33Describe;
    private Integer k33PlanState = SigninItemPlanStatus.NOPLAN.getType();
    private String k34=SigninItemPlanStatus.NOPLAN.getStatus();
    private String k34Describe;
    private Integer k34PlanState = SigninItemPlanStatus.NOPLAN.getType();

    @Override
    public String toString() {
        return "DailyGroupCheckinRecord{" +
                "recordDate='" + recordDate + '\'' +
                ", patientId=" + patientId +
                ", weekStart='" + weekStart + '\'' +
                ", monthStart='" + monthStart + '\'' +
                ", sourceDate=" + sourceDate +
                ", dateTag='" + dateTag + '\'' +
                ", recordStat=" + recordStat +
                '}';
    }

    public String printState(){
        return
                "k1PlanState=" + k1PlanState +
                ", k2PlanState=" + k2PlanState +
                ", k3PlanState=" + k3PlanState +
                ", k4PlanState=" + k4PlanState +
                ", k5PlanState=" + k5PlanState +
                ", k6PlanState=" + k6PlanState +
                ", k7PlanState=" + k7PlanState +
                ", k8PlanState=" + k8PlanState +
                ", k9PlanState=" + k9PlanState +
                ", k10PlanState=" + k10PlanState +
                ", k11PlanState=" + k11PlanState +
                ", k12PlanState=" + k12PlanState +
                ", k13PlanState=" + k13PlanState +
                ", k14PlanState=" + k14PlanState +
                ", k15PlanState=" + k15PlanState +
                ", k16PlanState=" + k16PlanState +
                ", k17PlanState=" + k17PlanState +
                ", k18PlanState=" + k18PlanState +
                ", k19PlanState=" + k19PlanState ;
    }

}
